package com.ruoyi.project.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.project.system.mapper.ProfessionalSubcontractingMapper;
import com.ruoyi.project.system.domain.ProfessionalSubcontracting;
import com.ruoyi.project.system.service.IProfessionalSubcontractingService;

/**
 * 专业分包Service业务层处理
 * 
 * @author ruoyi
 * @date 2021-10-15
 */
@Service
public class ProfessionalSubcontractingServiceImpl implements IProfessionalSubcontractingService 
{
    @Autowired
    private ProfessionalSubcontractingMapper professionalSubcontractingMapper;

    /**
     * 查询专业分包
     * 
     * @param id 专业分包主键
     * @return 专业分包
     */
    @Override
    public ProfessionalSubcontracting selectProfessionalSubcontractingById(Long id)
    {
        return professionalSubcontractingMapper.selectProfessionalSubcontractingById(id);
    }

    /**
     * 查询专业分包列表
     * 
     * @param professionalSubcontracting 专业分包
     * @return 专业分包
     */
    @Override
    public List<ProfessionalSubcontracting> selectProfessionalSubcontractingList(ProfessionalSubcontracting professionalSubcontracting)
    {
        return professionalSubcontractingMapper.selectProfessionalSubcontractingList(professionalSubcontracting);
    }

    /**
     * 新增专业分包
     * 
     * @param professionalSubcontracting 专业分包
     * @return 结果
     */
    @Override
    public int insertProfessionalSubcontracting(ProfessionalSubcontracting professionalSubcontracting)
    {
        return professionalSubcontractingMapper.insertProfessionalSubcontracting(professionalSubcontracting);
    }

    /**
     * 修改专业分包
     * 
     * @param professionalSubcontracting 专业分包
     * @return 结果
     */
    @Override
    public int updateProfessionalSubcontracting(ProfessionalSubcontracting professionalSubcontracting)
    {
        return professionalSubcontractingMapper.updateProfessionalSubcontracting(professionalSubcontracting);
    }

    /**
     * 批量删除专业分包
     * 
     * @param ids 需要删除的专业分包主键
     * @return 结果
     */
    @Override
    public int deleteProfessionalSubcontractingByIds(Long[] ids)
    {
        return professionalSubcontractingMapper.deleteProfessionalSubcontractingByIds(ids);
    }

    /**
     * 删除专业分包信息
     * 
     * @param id 专业分包主键
     * @return 结果
     */
    @Override
    public int deleteProfessionalSubcontractingById(Long id)
    {
        return professionalSubcontractingMapper.deleteProfessionalSubcontractingById(id);
    }
}
